package cuiying.rbac.domain.vo;

/**
 * 业务层返回给视图层的数据格式
 *
 * @author 崔颖
 * @since 2025/4/20 15:21
 */
public class Result {
    /**
     * 表示操作是否成功
     */
    public boolean success;
    public String message;
    public Object data;


    public static Result failure(String message) {
        Result result = new Result();
        result.message = message;
        return result;
    }

    public static Result success(String message, Object data) {
        Result result = new Result();
        result.success = true;
        result.data = data;
        return result;
    }
}

